import { defineConfig } from 'vite'
import vue from '@vitejs/plugin-vue'
import WindiCSS from 'vite-plugin-windicss'


// https://vitejs.dev/config/
export default defineConfig(
  {
  plugins: [vue(), WindiCSS()],
  resolve: {
    alias: {
      '@': '/src'
    }
  },
  server:{
    proxy:{
      '/api': {
        target: 'http://localhost:8848/',
        changeOrigin: true,
        rewrite: (path) => path.replace(/^\/api/, ''),
      },
    }
  },
})
